Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create new DiagnosticGroup for SUSPICIOUS_BREAKING_OUT_OF_OPTIONAL_CHAIN #4222

Conversation

jnowjack-lucidchart
Copy link
Contributor

Discussion on the Closure Compiler Discuss Group: https://groups.google.com/g/closure-compiler-discuss/c/ZpsidQkqdjk

Reasoning for change:

We have set --jscomp_error suspiciousCode in our codebase and noticed that we were getting warnings instead of errors for SUSPICIOUS_BREAKING_OUT_OF_OPTIONAL_CHAIN. We would like this to be an error instead of a warning in line with the other DiagnosticTypes defined in CheckSuspiciousCode.

There are concerns about adding this check to the existing suspiciousCode group (see the discussion group thread) so I've created a new DiagnosticGroup with just SUSPICIOUS_BREAKING_OUT_OF_OPTIONAL_CHAIN so that it can be configured to be an error.

@brad4d brad4d self-assigned this Feb 24, 2025
@brad4d
Copy link
Contributor

brad4d commented Feb 24, 2025

I'm going to try landing #4221 first. It might be OK, and it is a simpler change.

@brad4d
Copy link
Contributor

brad4d commented Feb 28, 2025

This is no longer needed, because #4221 was merged.

@brad4d brad4d closed this Feb 28, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants